{	Problem: http://codeforces.ru/problemset/problem/12/B
	Verdict: Accepted
}
uses sysutils;
var s,t:string; a:Array[1..10] of byte; i,k:longint; f:boolean;
procedure qsort(l,r:longint);
var i,j,x,y:longint;
begin
i:=l;
j:=r;
x:=a[(l+r) div 2];
repeat
  while a[i]<x do inc(i);
  while a[j]>x do dec(j);
  if i<=j then begin
    y:=a[i];
    a[i]:=a[j];
    a[j]:=y;
    inc(i);
    dec(j);
  end;
until i>j;
if l<j then qsort(l,j);
if i<r then qsort(i,r);
end;
begin
readln(s);
readln(t);
f:=true;
if (s='0') and (t='0') then f:=true else
if (s='0') or (length(s)<>length(t)) then f:=false else begin
  for i:=1 to length(s) do a[i]:=ord(s[i])-48;
  qsort(1,length(s));
  k:=1;
  while a[k]=0 do inc(k);
  if t[1]<>chr(a[k]+48) then f:=false else begin
    for i:=2 to k do
      if t[i]<>'0' then f:=false;
    if f then begin
      for i:=k+1 to length(s) do
        if chr(a[i]+48)<>t[i] then f:=false;
    end;
  end;
end;
if f then write('OK') else write('WRONG_ANSWER');
end.